#ifndef _SOURCE_STORE_H_
#define _SOURCE_STORE_H_

#include "source_private.h"

void sourcePsInit(void);

uint16 sourcePsRead(uint16 ps_key, void *ps_data, uint16 ps_size);

/****************************************************************************
NAME
    ps_write - Write a PSKey
*/
uint16 sourcePsWrite(uint16 ps_key, const void *ps_data, uint16 ps_size);

void sourcePsReadRemoteDeviceAddress(bdaddr *addr);

void sourcePsWriteRemoteDeviceAddress(const bdaddr *addr);

void sourcePsReadDualStreamSecondDeviceAddress(bdaddr *addr);

void sourcePsWriteDualStreamSecondDeviceAddress(const bdaddr *addr);

bool sourcePsGetFwUpgrade(void);

void sourcePsSetFwUpgrade(bool status);

void sourcePsGetVersion(uint8 *major, uint8 *minor, uint8 *patch);

void sourcePsHandleDeviceSetting(uint8* data);

void sourcePsGetCodecConfig(uint8 *aptxEnable, uint8 *aptxHDEnable, uint8 *aptxAdEnable, uint8 *aptxLLEnable);

void sourcePsSetCodecConfig(bool aptxEnable, bool aptxHDEnable, bool aptxAdEnable, bool aptxLLEnable);

APTX_AD_QUALITY_T sourcePsGetAptxAdQuality(void);

void sourcePsSetAptxAdQuality(APTX_AD_QUALITY_T quality);

void sourcePsReadDeviceSettings(uint8* data);

void sourcePsFactoryDefault(void);

uint8 sourcePsGetAudioLevel(AUDIO_SOURCE_T source_type);

void sourcePsSetAudioLevel(AUDIO_SOURCE_T source_type, uint8 level);

bool sourcePsGetAutoPowerOn(void);

void sourcePsSetAutoPowerOn(bool autoPowerOn);
#endif
